home *** CD-ROM | disk | FTP | other *** search
/ Complete Linux / Complete Linux.iso / docs / devel / tcl / itcl1_31.z / itcl1_31 / tcldev / itcl-1.3 / src / Makefile < prev    next >
Encoding:
Makefile  |  1993-11-14  |  6.9 KB  |  219 lines

  1. # Generated automatically from Makefile.in by configure.
  2. # ---------------------------------------------------------------------------
  3. #           [incr Tcl] - Object-oriented programming in Tcl
  4. # ---------------------------------------------------------------------------
  5. # This file is a Makefile for [incr Tcl].  If it has the name "Makefile.in"
  6. # then it is a template for a Makefile; to generate the actual Makefile,
  7. # run "./configure", which is a configuration script generated by the
  8. # "autoconf" program (constructs like "@foo@" will get replaced in the
  9. # actual Makefile.
  10. # ---------------------------------------------------------------------------
  11.  
  12. # ---------------------------------------------------------------------------
  13. # Things you can change to personalize the Makefile for your own site.
  14. # (You can make these changes in either Makefile.in or Makefile, but
  15. # changes to Makefile will get lost if you re-run the configuration script.)
  16. # ---------------------------------------------------------------------------
  17. # INSTALLATION DIRECTORIES
  18. # ---------------------------------------------------------------------------
  19.  
  20. # Top-level directory in which to install architecture-specific files:
  21. exec_prefix = $(ROOT)/usr
  22.  
  23. # Directory in which to install the archive libitcl.a:
  24. LIB_DIR = $(exec_prefix)/lib
  25.  
  26. # Directory in which to install the programs (itcl_wish and itcl_sh):
  27. BIN_DIR = $(exec_prefix)/bin
  28. XBIN_DIR = $(exec_prefix)/X386/bin
  29.  
  30. # ---------------------------------------------------------------------------
  31. # COMPILATION SOURCES/LIBRARIES
  32. # ---------------------------------------------------------------------------
  33.  
  34. # Tcl source directory (must contain tclInt.h)
  35. # (the configure script should find it; if not, edit below)
  36. TCL_INC = -I/usr/include/tcl
  37.  
  38. # Tk include directory
  39. # (the configure script should find it; if not, edit below)
  40. TK_INC = #-I/usr/include/tcl
  41.  
  42. # X11 include directory
  43. # (the configure script should find it; if it is /usr/include,
  44. # it will be commented out)
  45. X11_INC =     -I/usr/X386/include
  46.  
  47. # Tcl library
  48. # (the configure script should find it; if not, edit below)
  49. TCL_LIB = -ltcl
  50.  
  51. # Tk library
  52. # (the configure script should find it; if not, edit below)
  53. TK_LIB = -L/usr/X386/lib -ltk
  54.  
  55. # Linker switch(es) to use to link with the X11 library archive (the
  56. # configure script will try to set this value automatically, but you
  57. # can override it).
  58. X11_LIB = -L/usr/X386/lib -lX11
  59.  
  60. # Libraries to use when linking:  must include at least Tk, Tcl, Xlib,
  61. # and the math library (in that order).  The " -lm" part will be
  62. # replaced (or has already been replaced) with relevant libraries as
  63. # determined by the configure script.
  64. LIBS = $(TK_LIB) $(TCL_LIB) $(X11_LIB)  -lieee -lm
  65.  
  66. # Composite list of include files
  67. INCS = -I$(SRC_DIR) $(TCL_INC) $(TK_INC) $(X11_INC)
  68.  
  69. # To change the compiler switches, for example to change from -O
  70. # to -g, change the following line:
  71. CFLAGS = -O2
  72.  
  73. # To turn off the security checks that disallow incoming sends when
  74. # the X server appears to be insecure, reverse the comments on the
  75. # following lines:
  76. SECURITY_FLAGS =
  77. #SECURITY_FLAGS = -DTK_NO_SECURITY
  78.  
  79. # To disable ANSI-C procedure prototypes reverse the comment characters
  80. # on the following lines:
  81. PROTO_FLAGS =
  82. #PROTO_FLAGS = -DNO_PROTOTYPE
  83.  
  84. # To enable memory debugging reverse the comment characters on the following
  85. # lines.  Warning:  if you enable memory debugging, you must do it
  86. # *everywhere*, including all the code that calls Tcl, and you must use
  87. # ckalloc and ckfree everywhere instead of malloc and free.
  88. MEM_DEBUG_FLAGS =
  89. #MEM_DEBUG_FLAGS = -DTCL_MEM_DEBUG
  90.  
  91. # Some versions of make, like SGI's, use the following variable to
  92. # determine which shell to use for executing commands:
  93. SHELL =        /bin/sh
  94.  
  95. # ---------------------------------------------------------------------------
  96. # The information below is modified by the configure script when Makefile
  97. # is generated from Makefile.in.  You shouldn't normally modify any of
  98. # this stuff by hand.
  99. # ---------------------------------------------------------------------------
  100.  
  101. AC_FLAGS =        
  102. INSTALL =        /bin/install -c
  103. INSTALL_PROGRAM =    $(INSTALL)
  104. INSTALL_DATA =        $(INSTALL) -m 644
  105. RANLIB =        ranlib
  106. SRC_DIR =        .
  107. VPATH =            .
  108.  
  109. # ---------------------------------------------------------------------------
  110. # The information below should be usable as is.  The configure script
  111. # won't modify it and you shouldn't need to modify it either.
  112. # ---------------------------------------------------------------------------
  113.  
  114. CC = cc
  115. CC_SWITCHES = $(CFLAGS) $(INCS) $(AC_FLAGS) $(PROTO_FLAGS) \
  116.     $(SECURITY_FLAGS) $(MEM_DEBUG_FLAGS)
  117.  
  118. SRCS = itcl_class.c itcl_core.c \
  119.     itcl_methods.c itcl_objects.c itcl_vars.c \
  120.     itcl_util.c
  121.  
  122. OBJS = itcl_class.o itcl_core.o \
  123.     itcl_methods.o itcl_objects.o itcl_vars.o \
  124.     itcl_util.o
  125.  
  126. SOBJS = itcl_class.so itcl_core.so \
  127.     itcl_methods.so itcl_objects.so itcl_vars.so \
  128.     itcl_util.so
  129.  
  130. all:  libitcl.a itcl_wish itcl_sh
  131.  
  132. libitcl.a: $(OBJS)
  133.     rm -f libitcl.a
  134.     ar cr libitcl.a $(OBJS)
  135.     $(RANLIB) libitcl.a
  136.  
  137. libitcl.so.$(VERSION): $(SOBJS)
  138.     rm -f libitcl.so.$(VERSION)
  139.     ld -o libitcl.so.$(VERSION) -assert pure-text $(SOBJS)
  140.  
  141. itcl_wish: tkAppInit.o libitcl.a
  142.     $(CC) $(CC_SWITCHES) tkAppInit.o libitcl.a $(LIBS) -o itcl_wish
  143.  
  144. itcl_sh: tclAppInit.o libitcl.a
  145.     $(CC) $(CC_SWITCHES) tclAppInit.o libitcl.a $(TCL_LIB) -lieee -lm -o itcl_sh
  146.  
  147. test: itcl_sh
  148.     @( echo cd $(SRC_DIR)/../tests\; source all\; exit ) | ./itcl_sh
  149.  
  150. pure: tclAppInit.o tkAppInit.o libitcl.a
  151.     purify $(CC) $(CC_SWITCHES) tclAppInit.o libitcl.a $(TCL_LIB) -lm \
  152.         -o itcl_sh.pure
  153.     purify $(CC) $(CC_SWITCHES) tkAppInit.o libitcl.a $(LIBS) \
  154.         -o itcl_wish.pure
  155.  
  156. install:  libitcl.a itcl_wish itcl_sh
  157.     @for i in $(LIB_DIR) $(BIN_DIR) $(XBIN_DIR) ; \
  158.         do \
  159.         if [ ! -d $$i ] ; then \
  160.         echo "Making directory $$i"; \
  161.         mkdir $$i; \
  162.         chmod 755 $$i; \
  163.         else true; \
  164.         fi; \
  165.         done;
  166.     @echo "Installing libitcl.a"
  167.     @$(INSTALL_DATA) libitcl.a $(LIB_DIR)
  168.     @$(RANLIB) $(LIB_DIR)/libitcl.a
  169.     @echo "Installing shared (-pic) libitcl.a"
  170.     -@$(INSTALL_DATA) libitcl.so.$(VERSION) $(LIB_DIR)
  171.     @echo "Installing itcl_wish"
  172.     @$(INSTALL_PROGRAM) itcl_wish $(XBIN_DIR)
  173.     @echo "Installing itcl_sh"
  174.     @$(INSTALL_PROGRAM) itcl_sh $(BIN_DIR)
  175.  
  176. install-man:
  177.     @for i in $(MAN_DIR) $(MANN_DIR) ; \
  178.         do \
  179.         if [ ! -d $$i ] ; then \
  180.         echo "Making directory $$i"; \
  181.         mkdir $$i; \
  182.         chmod 755 $$i; \
  183.         else true; \
  184.         fi; \
  185.         done;
  186.     @cd $(SRC_DIR)/doc; for i in *.n; \
  187.         do \
  188.         echo "Installing doc/$$i"; \
  189.         rm -f $(MANN_DIR)/$$i; \
  190.         sed -e '/man\.macros/r man.macros' -e '/man\.macros/d' \
  191.             $$i > $(MANN_DIR)/$$i; \
  192.         chmod 444 $(MANN_DIR)/$$i; \
  193.         done;
  194.  
  195. Makefile: $(SRC_DIR)/Makefile.in
  196.     $(SHELL) config.status
  197.  
  198. clean:
  199.     rm -f *.o *.a *.so *.so.* core errs *~ \#* TAGS *.E a.out errors
  200.     rm -f itcl_wish itcl_sh *pure*
  201.  
  202. distclean: clean
  203.     rm -f Makefile config.status
  204.  
  205. lint:
  206.     $(LINT) $(INCS) $(SRCS)
  207.  
  208. .c.o:
  209.     $(CC) -c $(CC_SWITCHES) $<
  210.  
  211. .SUFFIXES: .so $(SUFFIXES)
  212. .c.so:
  213.     $(CC) -c $(CC_SWITCHES) -pic -O $<
  214.     mv $*.o $@
  215.  
  216. $(OBJS): itcl_class.h itcl_core.h \
  217.     itcl_methods.h itcl_objects.h itcl_vars.h \
  218.     itcl_util.h
  219.